package cn.ecommerce.course.module.users.controller.admin.users.vo;

import lombok.*;

import java.time.LocalDate;
import java.util.*;
import io.swagger.v3.oas.annotations.media.Schema;
import cn.ecommerce.course.framework.common.pojo.PageParam;
import org.springframework.format.annotation.DateTimeFormat;
import java.time.LocalDateTime;

import static cn.ecommerce.course.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND;

@Schema(description = "管理后台 - 电商平台用户分页 Request VO")
@Data
public class UsersPageReqVO extends PageParam {

    @Schema(description = "登录用户名（唯一）", example = "李四")
    private String account;

    @Schema(description = "手机号（唯一）")
    private String phone;

    @Schema(description = "邮箱（唯一）")
    private String email;

    @Schema(description = "用户昵称", example = "李四")
    private String nickname;

    @Schema(description = "头像URL")
    private String avatar;

    @Schema(description = "账号状态（0-禁用/1-正常/2-待验证）", example = "1")
    private Integer status;

    @Schema(description = "性别（0-未知/1-男/2-女）")
    private Integer gender;

    @Schema(description = "生日")
    private LocalDate birthday;

    @Schema(description = "最近登录时间")
    @DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
    private LocalDateTime[] lastLoginTime;

    @Schema(description = "最近登录IP")
    private String loginIp;

}